import re
import time
import requests
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
from bs4 import BeautifulSoup

url = ''
pages = '/page/'
movies_list=[]

chrome_options = Options()
chrome_options.add_argument("--headless")
driver = webdriver.Chrome(chrome_options=chrome_options)
# driver = webdriver.Chrome()
driver.get(url)
soup = BeautifulSoup(driver.page_source, features = 'lxml')
divs = soup.find_all('div',{'class':'item masonry-brick'})

for movies in divs:
    movies = movies.find_all('a',{'class':'movie-box'})
    movies = movies[0]
    movies =url + movies['href']
    movies_list.append(movies)

for page in range(2,50):
    driver.get(url+pages+str(page))
    soup = BeautifulSoup(driver.page_source,features='lxml')
    divs = soup.find_all('div',{'class':'item masonry-brick'})
    for movies in divs:
        movies = movies.find_all('a',{'class':'movie-box'})
        movies = movies[0]
        movies =url + movies['href']
        movies_list.append(movies)
i = 1
for m in movies_list:
    print(i,m)
    i += 1